import request from '@/utils/request'

// 用户画像分析
export function basicInfiApi() {
  return request({
    url: '/org/dashboard/profile/basic-info',
    method: 'get'
  })
}
// 产品销量排行Top10
export function topSalesApi() {
  return request({
    url: '/org/dashboard/products/top-sales',
    method: 'get'
  })
}
// 销量趋势图
export function salesTrendsApi() {
  return request({
    url: '/org/dashboard/sales/trends',
    method: 'get'
  })
}
// 累计设备投放总数
export function totalDeployedApi() {
  return request({
    url: '/org/dashboard/devices/total-deployed',
    method: 'get'
  })
}
// 累计设备投放总数
export function salesRealtimeApi() {
  return request({
    url: '/org/dashboard/sales/realtime',
    method: 'get'
  })
}
// 点位销售排行
export function salesRankingApi() {
  return request({
    url: '/org/dashboard/sales/ranking',
    method: 'get'
  })
}
// 每个‘区’设备投放总数
export function deviceMapApi() {
  return request({
    url: '/org/dashboard/devices/district-deployed',
    method: 'get'
  })
}
// 券包销售数据列表
export function getPackSalesListApi(params) {
  return request({
    url: '/operation/statistics/admin/pack-sales',
    method: 'get',
    params
  })
}
// 券包销售数据列表-单个券包列表
export function getPackItemSalesListApi(params) {
  return request({
    url: '/operation/statistics/admin/pack-sales/single',
    method: 'get',
    params
  })
}
// 用户分层数据列表
export function getUserLayerListApi(params) {
  return request({
    url: '/operation/statistics/admin/user-layer',
    method: 'get',
    params
  })
}
// 用户分层数据总览
export function getUserLayerTotalApi(params) {
  return request({
    url: '/operation/statistics/admin/user-layer/overview',
    method: 'get',
    params
  })
}
// 用户分层数据列表-设备
export function getItemMachineListApi(params) {
  return request({
    url: '/operation/statistics/admin/user-layer/machine',
    method: 'get',
    params
  })
}
// 用户分层数据列表-累计用户数
export function getItemTotalUserListApi(params) {
  return request({
    url: '/operation/statistics/admin/user-layer/total-user',
    method: 'get',
    params
  })
}
// 用户分层数据列表-新用户数
export function getItemNewUserListApi(params) {
  return request({
    url: '/operation/statistics/admin/user-layer/new-user',
    method: 'get',
    params
  })
}
// 用户分层数据列表-下单用户数
export function getItemOrderUserListApi(params) {
  return request({
    url: '/operation/statistics/admin/user-layer/order-user',
    method: 'get',
    params
  })
}
// 商品数据列表
export function getGoodsSalesListApi(params) {
  return request({
    url: '/operation/statistics/admin/combo-sales',
    method: 'get',
    params
  })
}
// 商品数据列表-投放点位
export function getGoodsSalesPositionListApi(params) {
  return request({
    url: '/operation/statistics/admin/combo-sales/position',
    method: 'get',
    params
  })
}
// 套餐销售数据总览
export function getcomboDataTotalApi(data) {
  return request({
    url: '/operation/statistics/admin/comboDataTotal',
    method: 'post',
    data
  })
}
// 套餐销售数据-数据明细列表
export function getcomboSalesListApi(params) {
  return request({
    url: '/operation/statistics/admin/comboSaleData',
    method: 'get',
    params
  })
}
// 套餐销售数据-详情列表
export function getcomboSalesDetailListApi(params) {
  return request({
    url: '/operation/statistics/admin/comboSaleInfo',
    method: 'get',
    params
  })
}
